<?php

namespace app\home\controller;

use think\Controller;
use think\Request;

class Login extends Controller
{

    public function login(){
        $this->view->engine->layout(false);
        return view('login');
    }
    /**
     * 显示资源列表
     *
     * @return \think\Response
     */
    public function register(){
        $this->view->engine->layout(false);
        return view('register');

    }
    public function phone(){
        $params = input();
        $this->validate($params,[
            'phone'=>'require|regex:/^1[3-9]\d{9}$/|unique:user,phone',
            'code|验证码'=>'require|length:4',
            'password|密码'=>'require|length:6,18|confirm:repassword',

        ]);
        if($validate->check($params)){
            
        }
    }
}
